<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8" />
</head>
<body>
    <div th:fragment="editBlock" class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true" style="display: none">

        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span
                            aria-hidden="true">&times;</span></button>
                    <h4 class="modal-title" id="myModalLabel"></h4>
                </div>
                <form id="editform" class="modal-body" action="#" >
                    <input type="hidden" name="guid"  />
                    <div class="form-group">
                        <label  class="form-label" th:for="permissionName" >权限名称</label>
                        <input type="text"  name="permissionName"  class="form-control"/>
                        <span  class="has-error"  id="permissionName_errorMsg"/>
                    </div>
                    <div class="form-group">
                        <label  class="form-label" th:for="url" >权限url</label>
                        <input type="text"  name="url"  class="form-control"/>
                        <span  class="has-error"  id="url_errorMsg"/>
                    </div>

                    <div class="form-group">
                        <label  class="form-label" th:for="parentList" >父权限</label>
                        <select name="parentGuid" class="form-control" data-required="true">
                            <option value="">请选择</option>
                            <option th:each="pParent:${selectList}"
                                    th:value="${pParent.guid}" th:text="${pParent.permissionName}"></option>
                        </select>
                        <span  class="has-error"  id="parentGuid_errorMsg"/>
                    </div>
                    <div class="form-group">
                        <label  class="form-label" th:for="sort" >权限顺序</label>
                        <input type="text"  name="sort"    class="form-control"/>
                        <span  class="has-error"  id="sort_errorMsg"/>
                    </div>
                    <div class="form-group">
                        <label  class="form-label" th:for="type"  >菜单等级</label>
                        <div class="radio-content">
                            <div class="radio-item"><input type="radio" name="type"  value="1" />一级</div>
                            <div class="radio-item"><input type="radio" name="type"  value="2" />二级</div>
                        </div>
                        <span  class="has-error"  id="type_errorMsg"/>
                    </div>
                    <div class="form-group">
                        <label   class="form-label" th:for="img" >图标</label>
                        <input type="text"  name="img" class="form-control"/>
                        <span  class="has-error"  id="img_errorMsg"/>
                    </div>

                    <div class="form-group form-group-line">
                        <label  class="form-label" th:for="remark" >说明</label>
                        <textarea  name="remark"  class="form-control" th:inline="text"/>
                        <span class="has-error" id="remark_errorMsg"/>
                    </div>


                </form>
                <div class="modal-footer">
                    <button type="button" class="model-btn" th:onclick="'javascript:formSave(\'resources\');'">保存</button>
                    <button type="button" class="model-btn" data-dismiss="modal">关闭</button>
                </div>
            </div>
        </div>
    </div>

</body>
</html>